package question1.IO;

import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.IOException;

public class IODemo {
    public static void main(String[] args) throws IOException {
        FileInputStream fis = new FileInputStream("Day_11\\src\\question1\\IO\\aaa.txt");
        FileInputStream fis1 = new FileInputStream("Day_11\\src\\question1\\IO\\aaa.txt");
        FileOutputStream fos = new FileOutputStream("Day_11\\src\\question1\\IO\\bbb.txt");
        FileOutputStream fos1 = new FileOutputStream("Day_11\\src\\question1\\IO\\ccc.txt");
        int l;
        while ((l=fis.read())!=-1){
              fos.write(l);
        }
        fos.close();
        byte[] b=new byte[1024];
        int len;
        while ((len=fis1.read(b))!=-1){
            fos1.write(b,0,len);

        }
        fis.close();
        fos1.close();
    }
}
